#include<stdio.h>
#include<stdbool.h>
bool IsPalindrome(char *word, int size)
{
    int left = 0;
    int right = size - 1;
    while (left < right)
    {
        if (word[left] != word[right])
        {
            return false;
        }
        left++;
        right--;
    }
    return true;
}

char *firstPalindrome(char **words, int wordsSize)
{
    for (int i = 0; i < wordsSize; i++)
    {
        int len = strlen(words[i]);
        if (IsPalindrome(words[i], len) == true)
        {
            return words[i];
        }
    }
    return "";
}